def calcSum(beg,end):
    sum = 0
    for i in range(beg,end + 1):
        sum += i
    print(f'求{beg}到{end}这个公差为1的数列的和为{sum}')

calcSum(1,100)
